<?php
/**
 * Created by PhpStorm.
 * User: Administrator
 * Date: 2019/7/1 0001
 * Time: 上午 11:05
 */

namespace app\sports_admin\controller;

use app\sports_admin\service\AppExplain as AppExplainService;
use app\sports_admin\vaildate\AppExplain as AppExplainVaildate;
class AppExplain extends Base
{
    /**
     * app用户协议首页
     */
    public function index()
    {
        return view('index');
    }
    /**
     * 获取app首页用户协议列表
     */
    public function getList()
    {
        return AppExplainService::index();
    }
    /**
     * app使用说明添加页面
     */
    public function add()
    {
        return view('add');
    }
    /**
     * app使用说明添加
     */
    public function insert()
    {
        (new AppExplainVaildate())->insert();
        return AppExplainService::insert();
    }
    /**
     * 删除使用说明
     */
    public function delete()
    {
        (new AppExplainVaildate())->go_check();
        return AppExplainService::delete();
    }
}